package com.lantosec.hmrp.modules.supplier.mapper;

import com.baomidou.mybatisplus.core.mapper.BaseMapper;
import com.baomidou.mybatisplus.extension.plugins.pagination.Page;
import com.lantosec.hmrp.core.kit.PageVO;
import com.lantosec.hmrp.modules.supplier.entity.SupplierLinkman;
import com.lantosec.hmrp.modules.supplier.vo.SupplierLinkmanVO;
import org.apache.ibatis.annotations.Param;

import java.util.List;

/**
 * <p>
 * 供应商联系人 Mapper 接口
 * </p>
 *
 * @author AutoCode
 * @since 2020-02-20
 */
public interface SupplierLinkmanMapper extends BaseMapper<SupplierLinkman> {

    /**
     * 供应商联系人查询
     * @param page
     * @param supplierCode
     * @param linkmanName
     * @param linkmanTel
     * @return
     */
    public PageVO<SupplierLinkmanVO> querySupplierLinkman(PageVO<SupplierLinkman> page,
                                                          @Param("supplierCode") String supplierCode,
                                                          @Param("linkmanName") String linkmanName,
                                                          @Param("linkmanTel") String linkmanTel,
                                                          @Param("salesmanFlag") Integer salesmanFlag);


    /**
     * 查询供应商下的业务员
     * @param supplierCode
     * @return
     */
    public Page<SupplierLinkmanVO> getBySupplierCode(Page<SupplierLinkman> page,@Param("supplierCode") String supplierCode);

}
